package com.ruoyi.erp.service.impl;

import java.util.List;

import com.ruoyi.common.annotation.DataSource;
import com.ruoyi.common.enums.DataSourceType;
import com.ruoyi.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.erp.mapper.BzFaCardsMapper;
import com.ruoyi.erp.domain.BzFaCards;
import com.ruoyi.erp.service.IBzFaCardsService;

/**
 * 资产增加Service业务层处理
 * 
 * @author ztj
 * @date 2023-04-10
 */
@Service
public class BzFaCardsServiceImpl implements IBzFaCardsService 
{
    @Autowired
    private BzFaCardsMapper bzFaCardsMapper;

    /**
     * 查询资产增加
     * 
     * @param id 资产增加主键
     * @return 资产增加
     */
    @Override
    public BzFaCards selectBzFaCardsById(Long id)
    {
        return bzFaCardsMapper.selectBzFaCardsById(id);
    }

    /**
     * 查询资产增加列表
     * 
     * @param bzFaCards 资产增加
     * @return 资产增加
     */
    @Override
    public List<BzFaCards> selectBzFaCardsList(BzFaCards bzFaCards)
    {
        return bzFaCardsMapper.selectBzFaCardsList(bzFaCards);
    }

    @Override
    public List<BzFaCards> selectBzFaCardsListErp(BzFaCards bzFaCards)
    {
        return bzFaCardsMapper.selectBzFaCardsListErp(bzFaCards);
    }

    @Override
    public List<BzFaCards> selectBzFaCardsList(Long[] ids)
    {
        return bzFaCardsMapper.selectBzFaCardsByIds(ids);
    }

    @Override
    public List<BzFaCards> selectBzFaCardsListErp(Long[] ids)
    {
        return bzFaCardsMapper.selectBzFaCardsByIdsErp(ids);
    }
    /**
     * 新增资产增加
     * 
     * @param bzFaCards 资产增加
     * @return 结果
     */
    @Override
    public int insertBzFaCards(BzFaCards bzFaCards)
    {
        bzFaCards.setCreateTime(DateUtils.getNowDate());
        return bzFaCardsMapper.insertBzFaCards(bzFaCards);
    }

    /**
     * 修改资产增加
     * 
     * @param bzFaCards 资产增加
     * @return 结果
     */
    @Override
    public int updateBzFaCards(BzFaCards bzFaCards)
    {
        bzFaCards.setUpdateTime(DateUtils.getNowDate());
        return bzFaCardsMapper.updateBzFaCards(bzFaCards);
    }

    /**
     * 批量删除资产增加
     * 
     * @param ids 需要删除的资产增加主键
     * @return 结果
     */
    @Override
    public int deleteBzFaCardsByIds(Long[] ids)
    {
        return bzFaCardsMapper.deleteBzFaCardsByIds(ids);
    }

    /**
     * 删除资产增加信息
     * 
     * @param id 资产增加主键
     * @return 结果
     */
    @Override
    public int deleteBzFaCardsById(Long id)
    {
        return bzFaCardsMapper.deleteBzFaCardsById(id);
    }
}
